﻿<window:MetroDPIWindow x:Class="CircuitDiagram.winDocumentProperties"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:window="clr-namespace:CircuitDiagram.DPIWindow;assembly=CircuitDiagram.DPIWindow"
        Title="Document Properties" Height="365" Width="400" WindowStartupLocation="CenterOwner" ShowInTaskbar="False" ResizeMode="NoResize"
        TitleCaps="False" WindowTransitionsEnabled="False" EnableDWMDropShadow="True">
    <Window.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/VS/Colors.xaml" />
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/VS/Styles.xaml" />
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>
    </Window.Resources>
    <Grid>
        <TabControl Margin="12,12,12,47" Style="{StaticResource CDTabControl}">
            <TabItem Name="tabInformation" Header="Information">
                <Grid>
                    <Grid.RowDefinitions>
                        <RowDefinition Height="27" />
                        <RowDefinition Height="27" />
                        <RowDefinition Height="27" />
                        <RowDefinition Height="27" />
                        <RowDefinition Height="27" />
                        <RowDefinition Height="27" />
                    </Grid.RowDefinitions>
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition />
                        <ColumnDefinition />
                    </Grid.ColumnDefinitions>
                    <Label Name="lblDimensions" Grid.Row="0" Grid.Column="0" Content="Dimensions" Height="28" HorizontalAlignment="Left" VerticalAlignment="Center" />
                    <Label Name="lblFormat" Grid.Row="1" Grid.Column="0" Content="Format" Height="28" HorizontalAlignment="Left" VerticalAlignment="Center" />
                    <Label Name="lblApplication" Grid.Row="2" Grid.Column="0" Content="Application" Height="28" HorizontalAlignment="Left" VerticalAlignment="Center" />
                    <TextBox Name="tbxDimensions" Grid.Column="1" Grid.Row="0" Height="28" VerticalAlignment="Center" Style="{StaticResource SelectLabel}" IsReadOnly="True" />
                    <TextBox Name="tbxFormat" Text="{Binding Path=Metadata.Format}" Grid.Column="1" Grid.Row="1" Height="28" VerticalAlignment="Center" Style="{StaticResource SelectLabel}" IsReadOnly="True" />
                    <TextBox Name="tbxApplication" Text="{Binding Path=Metadata.Application}" Grid.Column="1" Grid.Row="2" Height="28" VerticalAlignment="Center" Style="{StaticResource SelectLabel}" IsReadOnly="True" />
                    <Label Name="lblApplicationVersion" Grid.Row="3" Grid.Column="0" Content="Application Version" Height="28" HorizontalAlignment="Left" VerticalAlignment="Center" />
                    <TextBox Name="tbxApplicationVersion" Text="{Binding Path=Metadata.AppVersion}" Grid.Column="1" Grid.Row="3" Height="28" VerticalAlignment="Center" Style="{StaticResource SelectLabel}" IsReadOnly="True" />
                    <Label Name="lblCreator" Grid.Row="4" Grid.Column="0" Content="Creator" Height="28" HorizontalAlignment="Left" VerticalAlignment="Center" />
                    <TextBox Name="tbxCreator" Text="{Binding Path=Metadata.Creator}" Grid.Column="1" Grid.Row="4" Height="28" VerticalAlignment="Center" Style="{StaticResource SelectLabel}" IsReadOnly="True" />
                    <Label Name="lblCreated" Grid.Row="5" Grid.Column="0" Content="Created" Height="28" HorizontalAlignment="Left" VerticalAlignment="Center" />
                    <TextBox Name="tbxCreated" Text="{Binding Path=Metadata.Created}" Grid.Column="1" Grid.Row="5" Height="28" VerticalAlignment="Center" Style="{StaticResource SelectLabel}" IsReadOnly="True" />
                </Grid>
            </TabItem>
            <TabItem Name="tabFields" Header="Fields">
                <Grid>
                    <Label Name="lblTitle" Content="Title" Height="28" HorizontalAlignment="Left" Margin="6,6,0,0" VerticalAlignment="Top" />
                    <TextBox Name="tbxTitle" Text="{Binding Path=Metadata.Title}" Height="23" Margin="124,8,6,0" VerticalAlignment="Top" />
                    <Label Name="lblDescription" Content="Description" Height="28" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="6,37,0,0" />
                    <TextBox Name="tbxDescription" Text="{Binding Path=Metadata.Description}" Height="72" AcceptsReturn="True" Margin="124,37,6,0" VerticalScrollBarVisibility="Auto" VerticalAlignment="Top" />
                </Grid>
            </TabItem>
            <TabItem Name="tabEmbedded" Header="Embedded">
                <Grid>
                    <Label Name="lblChooseEmbedComponents" Content="Choose which components to embed." Height="28" HorizontalAlignment="Left" Margin="6,6,0,0" VerticalAlignment="Top" />
                    <ListBox Margin="6,40,6,6" Name="lbxEmbedComponents" Width="332" Height="189">
                        <ListBox.ItemTemplate>
                            <DataTemplate>
                                <StackPanel Orientation="Horizontal">
                                    <CheckBox IsChecked="{Binding IsEmbedded}" VerticalAlignment="Center" Margin="0,0,5,0" />
                                    <TextBlock Text="{Binding Description.ComponentName}" />
                                </StackPanel>
                            </DataTemplate>
                        </ListBox.ItemTemplate>
                    </ListBox>
                </Grid>
            </TabItem>
            <TabItem Name="tabComponents" Header="Components">
                <Grid>
                    <Label Name="lblUsingComponents" Content="This document is using the following components:" Height="28" HorizontalAlignment="Left" Margin="6,6,0,0" VerticalAlignment="Top" />
                    <TreeView Margin="6,40,6,6" Name="trvComponents" Height="189" Width="332" />
                </Grid>
            </TabItem>
        </TabControl>
        <Button Content="Close" Height="23" HorizontalAlignment="Right" Margin="0,0,12,12" Name="btnClose" VerticalAlignment="Bottom" Width="75" Click="btnClose_Click" IsCancel="True" />
    </Grid>
</window:MetroDPIWindow>
